package com.hgkj.cloud.customer.enums;

public enum TasksMethodEnum {
    tasks_create(0,"创建中"),
    tasks_ready(1,"创建完成（未发布）"),
    tasks_doing(2,"已发布（正在执行"),
    tasks_finish(3,"已完成"),
    tasks_del(4,"已删除"),
    tasks_cancel(10,"取消");


    private  Integer key;
    private String value;

    TasksMethodEnum(Integer key , String value){
        this.key = key;
        this.value = value;
    }

    public static TasksMethodEnum getByKey(Integer key) {
        for (TasksMethodEnum collectionStatus : TasksMethodEnum.values()) {
            if (collectionStatus.getKey().equals(key)) {
                return collectionStatus;
            }
        }
        return null;
    }

    public Integer getKey() {
        return key;
    }

    public String getValue() {
        return value;
    }
}
